import Vue from 'vue'
import VueRouter from 'vue-router'
Vue.use(VueRouter)
const base = window.__POWERED_BY_QIANKUN__ ? '#/qiankun' : ''
const routes = [
    {
        path: '/',
        redirect: '/qiankun/home'
    },
    {
        path: '/qiankun/home',
        name:'home',
        component: () => import('@/views/Home/index.vue')
    },
    {
        path: '/qiankun/about',
        name:'about',
        component: () => import('@/views/About/index.vue')
    }
]
// routes.map(item=>{
//     item.path = base + item.path
// })
const router = new VueRouter({
    mode: 'hash',
    routes
})
export default router